<!--
直播分类列表
 add by yyp 2019-05-17
-->
<template lang="pug">
  keep-alive
    kalix-table(bizKey="Classify" title='直播分类列表' ref="kalixTable"
    v-bind:tableFields="tableFields"
    v-bind:targetURL="ClassifyURL"
    v-bind:bizDialog="classifyDialog"
    v-bind:btnList="classifyBtnList"
    v-bind:toolbarBtnList="toolbarBtnList"
    bizSearch="classifySearch")
      template(slot="tableColumnSlot")
        el-table-column(prop="name" label="直播分类名称" align="center")
        el-table-column(prop="imgUrl" label="直播分类图片")
          template(slot-scope="scope")
            img(:src="scope.row.imgUrl" width="100px" readonly="readonly")
</template>

<script type="text/ecmascript-6">
  import {ClassifyURL} from '../../config.toml'
  import {classifyConfigBtnList} from './config'
  import KalixTable from '../../../../../components/corelib/components/common/baseTable'

  export default {
    name: 'kalix-mooc-classify',
    components: {KalixTable},
    data() {
      return {
        ClassifyURL: ClassifyURL,
        tableFields: [
          {prop: 'name', label: '直播分类名称'},
          {prop: 'imgUrl', label: '直播分类图片'}
        ],
        classifyDialog: [
          {id: 'add', dialog: 'classifyAdd'},
          {id: 'edit', dialog: 'classifyEdit'},
          {id: 'view', dialog: 'classifyView'}
        ],
        classifyBtnList: classifyConfigBtnList,
        toolbarBtnList: [
          {id: 'add', isShow: true, title: '添加', icon: 'icon-pinleizengjia', isPermission: true}
        ]
      }
    }
  }
</script>

<style scoped lang="stylus">

</style>
